package com.insurance.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.util.Date;

import com.insurance.common.enums.EnterpriseCardTypeEnum;
import lombok.Data;
import org.apache.commons.lang.StringUtils;

/**
 * 投被保险人
 * 
 * @date 2020-10-11 13:34:17
 */
@Data
@TableName("tb_proposal_customer")
public class ProposalCustomerEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * $column.comments
	 */
	@TableId
	private String customerId;
	/**
	 * $column.comments
	 */
	private String customerName;
	/**
	 * $column.comments
	 */
	private String sex;
	/**
	 * $column.comments
	 */
	private String email;
	/**
	 * $column.comments
	 */
	private String birthday;
	/**
	 * $column.comments
	 */
	private String telephoneNumber;
	/**
	 * $column.comments
	 */
	private String personType;
	/**
	 * $column.comments
	 */
	private String cardType;
	/**
	 * $column.comments
	 */
	private String cardId;
	/**
	 * 联系人
	 */
	private String linkManName;
	/**
	 * $column.comments
	 */
	private String address;
	/**
	 * $column.comments
	 */
	private String customerType;
	/**
	 * $column.comments
	 */
	private String productId;
	/**
	 * $column.comments
	 */
	private String proposalId;
	/**
	 * $column.comments
	 */
	private String proposalNo;
	/**
	 * $column.comments
	 */
	private String sellerId;
	/**
	 * $column.comments
	 */
	private Date createTime;
	/**
	 * $column.comments
	 */
	private Long excelLogId;

	/**
	 * 证件类型文本
	 */
	@TableField(exist=false)
	private String enterpriseCardTypeText;

	public String getEnterpriseCardTypeText() {
		return !StringUtils.isBlank(this.cardType) ? EnterpriseCardTypeEnum.getMessage(this.cardType) : "";
	}

	public void setEnterpriseCardTypeText(String enterpriseCardTypeText) {
		this.enterpriseCardTypeText = enterpriseCardTypeText;
	}

}
